package cn.tedu.guan;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Lazy;
import org.springframework.context.annotation.Scope;

@Configuration
public class Config {

    @Bean
    @Lazy
    //@Scope("prototype")
    public RedHare redHare(){
        System.out.println("red run");
        return  new RedHare();
    }
    @Bean
    public DragonBlade dragonBlade(){
        return new DragonBlade();
    }

    /*@Bean
    public GuanYu guan(RedHare redHare,DragonBlade dragonBlade){
        GuanYu gy=new GuanYu();
        gy.setDragonBlade(dragonBlade);
        gy.setRedHare(redHare);
        return gy;
    }*/



}
